# 声明一个 cmake 工程
project( demo_curl )


find_package(CURL REQUIRED)
include_directories(${CURL_INCLUDE_DIR})
# add .h文件
file( GLOB header_list http_post.h )
# add .cpp文件
file( GLOB source_list http_post.cpp )

#==============
# generat bin  
#==============
add_executable(${PROJECT_NAME} main.cpp ${header_list} ${source_list})
add_executable(${PROJECT_NAME}_post main_post.cpp ${header_list} ${source_list})
target_link_libraries(${PROJECT_NAME} ${CURL_LIBRARIES})
target_link_libraries(${PROJECT_NAME}_post ${CURL_LIBRARIES})